package com.iflytek.feignclients;

import com.iflytek.feignclients.impl.IHystrixClientImpl;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestParam;

/**
 * @author yfliu9
 * @version 1.0
 * @description: TODO
 * @date 2021/9/6 20:42
 */
//fallback当调用的服务不可用时，默认的备选处理
@FeignClient(value = "HYSTRIX", fallback = IHystrixClientImpl.class)
public interface IHystrixClient {

    @GetMapping("/demo")
    String demo(@RequestParam("id") Integer id);
}
